package style.zcyLeetCode.a_0005_二叉树;

/**
 * 折纸算法（类 二叉树  左凹 右凸）
 */
public class PaperFolding {
    public static void printAllFolds(int N) {
        printProcess(1, N, true);
    }

    public static void printProcess(int i, int N, boolean down) {
        if (i > N) return;
        printProcess(i + 1, N, true);
        System.out.println(down ? "down" : "up ");
        printProcess(i + 1, N, false);
    }

    public static void main(String[] args) {
        int N = 4;
        printAllFolds(N);
    }
}
